package com.kintreda.ieco_server.module.system.service.impl;

import com.kintreda.ieco_server.bean.system.City;
import com.kintreda.ieco_server.core.service.impl.BaseServiceImpl;
import com.kintreda.ieco_server.module.system.service.ICityService;
import org.springframework.stereotype.Service;

import java.util.List;

/**
 * @Created by IntelliJ IDEA
 * @Project_Name ieco_server
 * @Package com.kintreda.ieco_server.module.system.service.impl
 * @Author ZhongYao_H
 * @Date 2019/5/21:18:16
 * @Year 2019 Month 05 Day 21
 * @Date_zh 2019 年 五月 星期二
 */
@Service
public class CityServiceImpl extends BaseServiceImpl<City,String> implements ICityService {
    @Override
    public Boolean isadd(String cityName) {
        List<City> query = query("from City where name = ?", new Object[]{cityName});
        return query.size()>0;
    }
}
